package com.ganbing518.commons.test.annotation.service.impl;

import com.alibaba.fastjson.JSON;
import com.ganbing518.commons.annotation.BizLogger;
import com.ganbing518.commons.test.annotation.dto.AnnotationDto;
import com.ganbing518.commons.test.annotation.service.AnnotationService;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Service;
import org.springframework.validation.annotation.Validated;

/**
 * Description:
 *
 * @author gan bing
 * @version V1.0
 * @date 2018-06-25 17:16
 */
@Service
@Validated
public class AnnotationServiceImpl implements AnnotationService {

    private final static Logger LOGGER = LoggerFactory.getLogger(AnnotationServiceImpl.class);

    @Override
    @BizLogger(isCatchException = false)
    public void sayHello(AnnotationDto annotationDto) {
        LOGGER.info(JSON.toJSONString(annotationDto));
    }
}
